<template>
  <div>
    <component
      ref="component"
      :is="componentId"
    ></component>
  </div>
</template>

<script>
export default {
  name: 'index',
  props: {
    item: {
      type: Object
    }
  },
  data() {
    return {
      componentId: ''
    }
  },

  async created() {
    this.componentId = resolve => require.ensure([], () => resolve(require(`@/views/${this.item.url}`)))
  }
}
</script>

<style scoped>

</style>
